# _*_ coding utf-8 _*_
# FILENAME：.py
# DESCRIPTION: 生产队列 Model
# AUTH: ZB
# DATE: 2022/6/2 10:00 下午

from sqlalchemy import Column, String, Integer, DATETIME
from models.baseModel import BaseModel


## 生产队列主表
class ProduceQueueModel(BaseModel):
    # 表的名字:
    __tablename__ = 'produce_queue'
    # 表的结构:
    production_line = Column(Integer, comment='生产线 1：焊装 2：涂装 3：总装')
    version_name = Column(String(255), index=True, comment='版本ID')
    factory_id = Column(Integer, comment='工厂ID')
    # 添加表注释
    __table_args__ = ({'comment': '生产队列主表'})


## 生产队列详情表
class ProduceQueueDetailsModel(BaseModel):
    # 表的名字:
    __tablename__ = 'produce_queue_details'
    # 表的结构:
    produce_queue_id = Column(Integer, index=True, comment='生产队列主表ID')
    car_model = Column(String(64), comment='车型')
    optional_equipment = Column(String(64), comment='选装件')
    colour_code = Column(String(32), comment='颜色代码')
    colour_name = Column(String(32), comment='颜色名')
    # 添加表注释
    __table_args__ = ({'comment': '生产队列详情表'})
